<#setting number_format = "#"/>
<STYLE type=text/css>@import url( ${contextPath}/templates/${templateName}/admin/style.css );</STYLE>

<form accept-charset="${encoding}" name="form" action="${contextPath}/jforum${extension}" method="post">
<input type="hidden" name="action" value="insert">
<input type="hidden" name="module" value="${moduleName}">
<input type="hidden" name="securityHash" value="${securityHash}">

<TABLE class=forumline cellSpacing=1 cellPadding=3 width="100%" border=0>
<TR>
<TH class="thhead" vAlign=center colSpan=7 height=25>${I18n.getMessage("Banner.adminTitle")}</TH>
</TR>
<#if errorMessage?exists>
<TR>
<TD class=row2 colSpan=7>&nbsp;
<SPAN class=nav>
	<center><font color="#ff0000"><b>${errorMessage}</b></font></center>
</SPAN></TD>
</TR>
</#if>

<tr>
<td class='catleft'><span class='gen'>${I18n.getMessage("Banner.comment")}</span></td>
<td class='catleft'><span class='gen'>${I18n.getMessage("Banner.activated")}</span></td>
<td class='catleft'><span class='gen'>${I18n.getMessage("Banner.clicks")}</span></td>
<td class='catleft'><span class='gen'>${I18n.getMessage("Banner.views")}</span></td>
<td class='catleft'><span class='gen'>${I18n.getMessage("Banner.placement")}</span></td>
<td class='catleft'><span class='gen'>${I18n.getMessage("Edit")}</span></td>
<td class='catleft'><span class='gen'>${I18n.getMessage("Delete")}</span></td>
</tr>

<#assign counter = 1/>
<#list banners as banner>

	<TR>
	<TD class=row2><span class="gen">${banner.comment}</span></TD>
	<TD class=row2><span class="gen"><#if banner.active>${I18n.getMessage("User.yes")}<#else>${I18n.getMessage("User.no")}</#if></span></TD>
	<TD class=row2><span class="gen">${banner.clicks}</span></TD>
	<TD class=row2><span class="gen">${banner.views}</span></TD>
	<TD class=row2><span class="gen">
	  <#switch banner.placement>
	    <#case 1>
	      ${I18n.getMessage("Banner.topLeft")}
	      <#break>
	    <#case 2>
	      ${I18n.getMessage("Banner.topCenter")}
	      <#break>
	    <#case 3>
	      ${I18n.getMessage("Banner.topRight")}
	      <#break>
	    <#case 4>
	      ${I18n.getMessage("Banner.bottomLeft")}
	      <#break>
	    <#case 5>
	      ${I18n.getMessage("Banner.bottomCenter")}
	      <#break>
	    <#case 6>
	      ${I18n.getMessage("Banner.bottomRight")}
	      <#break>
	  </#switch>
	</span></TD>
	<TD class=row2><span class="gen"><a href="${contextPath}/${moduleName}/edit/${banner.id}${extension}">${I18n.getMessage("Edit")}</a></span></TD>
	<TD class=row2><span class="gen"><a href="${contextPath}/${moduleName}/delete/${banner.id}${extension}">${I18n.getMessage("Delete")}</a></span></TD>
	</TR>

        <#assign counter = counter + 1/>
</#list>

<TR align="center">
<TD class="catbottom" colSpan=7 height=28>
<INPUT class=mainoption type=submit value="${I18n.getMessage("Banner.newBanner")}" name=submit>
</TD></TR></TBODY></TABLE>
</form>
